package com.steakliu.event.order.controller;

import com.steakliu.event.order.service.OrderService;
import com.steakliu.event.order.dto.OrderDTO;
import lombok.AllArgsConstructor;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**

/**
 * 功能说明：下单
 *
 * <p>
 * Original @Author: steakliu-刘牌, 2022-06-25  20:00
 * <p>
 * Copyright (C)2020-2022  小四的技术之旅 All rights reserved.
 */
@RestController
@RequestMapping("/order")
@AllArgsConstructor
public class OrderController {

    final OrderService orderService;

    @PostMapping("/placeOrder")
    public String placeOrder(@RequestBody OrderDTO orderDTO){
        orderService.placeOrder(orderDTO);
        return "下单成功";
    }
}
